package com.clz.appdesign.appdependence.net.bean;

/**
 * @author yemao
 * @date 2017/4/9
 * @description 解析实体基类!
 */

public class BaseEntity<T> {
    private static String SUCCESS_CODE="200";//成功的code
    private String resultcode;
    private String reason;
    private int error_code;
    private T result;

    public int getError_code() {
        return error_code;
    }

    public void setError_code(int error_code) {
        this.error_code = error_code;
    }

    public boolean isSuccess(){
        return getResultCode().equals(SUCCESS_CODE);
    }
    public String getResultCode() {
        return resultcode;
    }

    public void setResultCode(String code) {
        this.resultcode = code;
    }

    public String getReason() {
        return reason;
    }

    public void setReason(String reason) {
        this.reason = reason;
    }

    public T getData() {
        return result;
    }

    public void setData(T data) {
        this.result = data;
    }

}
